def is_lychrel(num):
    for i in range(50):
        t = num + int(str(num)[::-1])
        if t == int(str(t)[::-1]):
            return False
        num = t
    return True


if __name__ == '__main__':
    count = 0
    for j in range(10000):
        if is_lychrel(j):
            print(j)
            count += 1
    print(count)
    print(is_lychrel(4994))
